.node {
  min-width: 200px;
  min-height: 120px;
  position: absolute;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  user-select: none;
  transform-origin: center;
  display: flex;
  flex-direction: column;
  border: 1px solid;
  color: #2d3748;
  font-size: 12px;
  z-index: 2;
}

.resize-handle {
  position: absolute;
  width: 10px;
  height: 10px;
  background: #4299e1;
  border-radius: 2px;
  z-index: 10;
}

.resize-handle.nw {
  left: -5px;
  top: -5px;
  cursor: nwse-resize;
}

.resize-handle.ne {
  right: -5px;
  top: -5px;
  cursor: nesw-resize;
}

.resize-handle.sw {
  left: -5px;
  bottom: -5px;
  cursor: nesw-resize;
}

.resize-handle.se {
  right: -5px;
  bottom: -5px;
  cursor: nwse-resize;
}

.resize-handle.n {
  left: 50%;
  top: -5px;
  margin-left: -5px;
  cursor: ns-resize;
}

.resize-handle.s {
  left: 50%;
  bottom: -5px;
  margin-left: -5px;
  cursor: ns-resize;
}

.resize-handle.w {
  left: -5px;
  top: 50%;
  margin-top: -5px;
  cursor: ew-resize;
}

.resize-handle.e {
  right: -5px;
  top: 50%;
  margin-top: -5px;
  cursor: ew-resize;
}

.node-header {
  padding: 8px 12px;
  background: #4a5568;
  border-top-left-radius: 4px;
  border-top-right-radius: 4px;
  font-weight: bold;
  cursor: move;
  border-bottom: 1px solid
}

.node-body {
  padding: 12px;
  display: flex;
  justify-content: space-between;
  min-height: 120px;
  border-top: 1px solid
}

.node-inputs,
.node-outputs {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.node-port {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  margin: 4px 0;
}

.node-input {
  padding-left: 8px;
}

.node-output {
  padding-right: 8px;
  justify-content: flex-end;
}

.port-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #4a5568;
}

.port-label {
  color: #4a5568;
}

.exec .port-dot {
  background-color: #48bb78;
}

.data .port-dot {
  background-color: #4299e1;
}

.node.selected {
  box-shadow: 0 0 0 3px #4299e1;
  border-color: #4299e1;
}

.node.dragging {
  opacity: 0.8;
  cursor: move;
}

.node-flow {
  border-color: #48bb78;
}

.node-procedure {
  border-color: #4299e1;
}

.node-product {
  border-color: #9f7aea;
}

.connection-preview {
  z-index: 10;
}